import request from '@/utils/request'

// 学生/管理员获取作业列表
export function getList(params) {
  return request({
    url: '/api/homeWorkStudent/list',
    method: 'get',
    params
  })
}

// 老师获取自己发布的作业列表
export function getTeacherHomeWorkList(params) {
  return request({
    url: '/api/homeWorkTeacher/list',
    method: 'get',
    params
  })
}

export function deleted(params) {
  return request({
    url: '/api/homeWorkStudent/delete',
    method: 'get',
    params
  })
}
export function update(params) {
  return request({
    url: '/api/homeWorkStudent/update',
    method: 'get',
    params
  })
}
export function getAllHomeWorkList() {
  return request({
    url: '/api/homeWorkStudent/listAll',
    method: 'get'
  })
}
export function addScore(data) {
  return request({
    url: '/api/homeWorkStudent/addScore',
    method: 'post',
    data
  })
}